"use strict";

function _instanceof(left, right) {
  if(right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
    return !!right[Symbol.hasInstance](left);
  } else {
    return left instanceof right;
  }
}

function _classCallCheck(instance, Constructor) {
  if(!_instanceof(instance, Constructor)) {
    throw new TypeError("Cannot call a class as a function");
  }
}

function _defineProperty(obj, key, value) {
  if(key in obj) {
    Object.defineProperty(obj, key, {value: value, enumerable: true, configurable: true, writable: true});
  } else {
    obj[key] = value;
  }
  return obj;
}

var HD = function HD(executor) {
  _classCallCheck(this, HD);

  this.promiseStatus = HD.PENDING;
  this.promiseResut = null;

  try {
    executor();
  } catch(err) {
    reject(err);
  }
};

_defineProperty(HD, "PENDING", 'pending');

_defineProperty(HD, "FULFILLED", 'fulfilled');

_defineProperty(HD, "REJECTED", 'rejected');

console.log(HD);
console.log( "PENDING" in HD, HD.hasOwnProperty("PENDING"), HD["PENDING"]);




